package com.zh.auth.controller;

import com.zh.auth.service.CallBySystemService;
import com.zh.web.base.ApiResult;
import com.zh.web.base.BaseController;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/auth/system")
@RequiredArgsConstructor
@Api(tags = "系统调用",hidden = true)
public class CallBySystemController extends BaseController {

    private final CallBySystemService callBySystemService;

    @ApiOperation("清除过期数据")
    @GetMapping("/clearAllExpiredData")
    public ApiResult<String> clearAllExpiredData() {
        return buildMsgPackage(callBySystemService.clearAllExpireData());
    }
}
